home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / borland / bc20p2.zip / BC20P2.BAT next >
DOS Batch File  |  1991-10-29  |  3KB  |  97 lines

  1. echo off
  2.  
  3. if not exist %1cs.lib goto NOSMALLLIB
  4. echo Patching small library...
  5. tlib %1cs.lib -*ctime -*delay
  6. rename ctime.obj ctimes.old
  7. rename delay.obj delays.old
  8. tlib %1cs.lib +ctime.obs +slongtoa.obj +delays.obj
  9. del slongtoa.obj
  10. del delays.obj
  11. del ctime.obs
  12. echo =============================================================
  13. if errorlevel 1 goto ERROR_NOTLIB
  14. goto MEDIUM
  15. :NOSMALLLIB
  16. echo Cannot find CS.LIB to patch small library.
  17.  
  18. :MEDIUM
  19. if not exist %1cm.lib goto NOMEDLIB
  20. echo Patching medium library...
  21. tlib %1cm.lib -*ctime -*delay
  22. rename ctime.obj ctimem.old
  23. rename delay.obj delaym.old
  24. tlib %1cm.lib +ctime.obm +mlongtoa.obj +delaym.obj
  25. del mlongtoa.obj
  26. del delaym.obj
  27. del ctime.obm
  28. echo =============================================================
  29. if errorlevel 1 goto ERROR_NOTLIB
  30. goto COMPACT
  31. :NOMEDLIB
  32. echo Cannot find CM.LIB to patch medium library.
  33.  
  34. :COMPACT
  35. if not exist %1cc.lib goto NOCOMPACTLIB
  36. echo Patching compact library...
  37. tlib %1cc.lib -*ctime  -*delay
  38. rename delay.obj delayc.old
  39. rename ctime.obj ctimec.old
  40. tlib %1cc.lib +ctime.obc +clongtoa.obj +delayc.obj
  41. del clongtoa.obj
  42. del delayc.obj
  43. del ctime.obc
  44. echo =============================================================
  45. if errorlevel 1 goto ERROR_NOTLIB
  46. goto LARGE
  47. :NOCOMPACTLIB
  48. echo Cannot find CC.LIB to patch compact library.
  49.  
  50. :LARGE
  51. if not exist %1cl.lib goto NOLARGELIB
  52. echo Patching large library...
  53. tlib %1cl.lib -*ctime -*delay
  54. rename delay.obj delayl.old
  55. rename ctime.obj ctimel.old
  56. tlib %1cl.lib +ctime.obl +llongtoa.obj +delayl.obj
  57. del llongtoa.obj
  58. del delayl.obj
  59. del ctime.obl
  60. echo =============================================================
  61. if errorlevel 1 goto ERROR_NOTLIB
  62. goto HUGE
  63. :NOLARGELIB
  64. echo Cannot find CL.LIB to patch large library.
  65.  
  66. :HUGE
  67. if not exist %1ch.lib goto NOHUGELIB
  68. echo Patching huge library...
  69. tlib %1ch.lib -*ctime  -*delay.obj
  70. rename delay.obj delayh.old
  71. rename ctime.obj ctimeh.old
  72. tlib %1ch.lib +ctime.obh +hlongtoa.obj +delayh.obj
  73. del hlongtoa.obj
  74. del delayh.obj
  75. del ctime.obh
  76. echo =============================================================
  77. if errorlevel 1 goto ERROR_NOTLIB
  78. goto DONE
  79. :NOHUGELIB
  80. echo Cannot find CH.LIB to patch huge library.
  81. goto DONE
  82.  
  83. :ERROR_NOOBJ
  84. echo An patch object module is not in the current directory.  Please use
  85. echo unzip on BC20P2.ZIP and try to patch again.
  86. goto DONE
  87.  
  88. :ERROR_NOTLIB
  89. echo A problem was encountered executing TLIB.  Either the Turbo Librarian
  90. echo cannot be located along your DOS path, or an error occurred.  Consult
  91. echo your Borland C++ Users Guide for more information on why TLIB might not
  92. echo be operating correctly.
  93.  
  94. :DONE
  95. cls
  96. echo Done.
  97.